<!DOCTYPE html>
<html lang="zh">
<head>
    <meta charset="UTF-8">
    <title>01-动态伪类_03-focus</title>
    <style>
        input:focus {
            color: red;
        }

        a:focus {
            color: yellow;
        }

        a:active {
            color: green;
        }
    </style>
</head>
<body>

<input type="text"><br>
<input type="text">

<a href="#">链接</a>

<a href="#">链接</a>

<a href="#">链接</a>

</body>
</html>